t = int(input())
s=[]
for i in range(t):
c = input()
c = c.split(' ')
if int(c[0])<int(c[1]):
if int(c[1])%int(c[0]) == 0:
s.append('Yes')
else:
s.append('No')
else:
s.append('No')
for i in range(len(s)):
print(s[i])
1409B - Minimum Product | 723B - Text Document Analysis |
1471C - Strange Birthday Party | 1199A - City Day |
1334A - Level Statistics | 67B - Restoration of the Permutation |
1734A - Select Three Sticks | 1734B - Bright Nice Brilliant |
357B - Flag Day | 937A - Olympiad |
1075A - The King's Race | 1734C - Removing Smallest Multiples |
1004C - Sonya and Robots | 922A - Cloning Toys |
817A - Treasure Hunt | 1136B - Nastya Is Playing Computer Games |
1388A - Captain Flint and Crew Recruitment | 592B - The Monster and the Squirrel |
1081A - Definite Game | 721C - Journey |
1400A - String Similarity | 1734E - Rectangular Congruence |
1312D - Count the Arrays | 424C - Magic Formulas |
1730C - Minimum Notation | 1730B - Meeting on the Line |
1730A - Planets | 302B - Eugeny and Play List |
1730D - Prefixes and Suffixes | 1515C - Phoenix and Towers |